Source for file SC_GraphBar.php
Documentation is available at SC_GraphBar.php
* This file is part of EC-CUBE
* Copyright(c) 2000-2011 LOCKON CO.,LTD. All Rights Reserved.
* http://www.lockon.co.jp/
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
require_once $ownDir . 'SC_GraphLine.php';
$bgw = BG_WIDTH, $bgh = BG_HEIGHT, $left = LINE_LEFT, $top = LINE_TOP,
$area_width = LINE_AREA_WIDTH, $area_height = LINE_AREA_HEIGHT) {
parent::SC_GraphLine($bgw, $bgh, $left, $top, $area_width, $area_height);
for($i = 0; $i < $this->line_max; $i++ ) {
for($i = 0; $i < $this->line_max; $i++ ) {
$arrPointList = $this->arrPointList[$line_no];
$count = count($arrPointList);
$half_scale = intval($this->area_width / ($count + 1) / 2);
$scale_width = intval($this->area_width / ($count + 1));
$bar_width = intval(($scale_width - (BAR_PAD * 2)) / $this->line_max);
$c_max = count($this->arrColor);
for($i = 0; $i < $count; $i++ ) {
$left = $arrPointList[$i][0] - $half_scale + BAR_PAD + ($bar_width * $line_no);
$top = $arrPointList[$i][1];
$right = $left + $bar_width;
$bottom = $this->top + $this->area_height;
imagefilledrectangle($this->image, $left + 2, $top + 2, $right + 2, $bottom, $this->shade_color);
//imagefilledrectangle($this->image, $left, $top, $right, $bottom, $this->arrColor[($i % $c_max)]);
imagefilledrectangle($this->image, $left, $top, $right, $bottom, $this->arrColor[$line_no]);
imagerectangle($this->image, $left, $top, $right, $bottom, $this->flame_color);
$arrData = $this->arrDataList[$line_no];
$arrPointList = $this->arrPointList[$line_no];
$count = count($arrPointList);
for($i = 0; $i < $count; $i++ ) {
$x = $arrPointList[$i][0];
$y = $arrPointList[$i][1];
$x_pos = $x - $text_width / 2;
Documentation generated on Fri, 24 Feb 2012 14:02:35 +0900 by Seasoft
|